package com.changcheng.service;

import com.changcheng.pojo.Do.PageInfo;
import com.changcheng.pojo.Product;
import com.changcheng.pojo.Role;
import com.changcheng.pojo.User;

import java.util.List;

/**
 * @author xuan
 * @create 2021--04--12
 */

public interface UserService {
    List<User>findAllUser(PageInfo pageInfo);
    int selectItemsNumber();

    public User findByUsername(String username);

    public List<String> findPermissionByUserId(int id);

    public void addUser(User user, int roleId);

    public List<Role> findAllRole();

    public int findIdByUsername(String username);

    public void addUserRole(int userId, int roleId);

    public Boolean updatePassword(String password, String username);

    //public List<String> findAllUserAndRole();

    public Boolean deleteUser(int id);


    public List<String> findCurrentUserRole(int role);
}
